import request from '@/utils/request'

// 新增公寓
export function addApartment(data) {
  return request({
    url: '/apartment/apartment',
    method: 'post',
    data: data
  })
}

/* 获取公寓信息 */
export function getApartmentInfo() {
  return request({
    url: '/apartment/apartment',
    method: 'get',
  })
}

/* 编辑公寓信息 */
export function editApartment(data) {
  return request({
    url: '/apartment/apartment',
    method: 'put',
    data: data
  })
}

export default {
  addApartment,
  editApartment,
  getApartmentInfo,
}